package cn.bone.motan.jingzhouArea.data;


import java.util.ArrayList;
import java.util.List;

/**
 * Created by MD-01 on 2017/3/15.
 */
public class TempConfig {

    public static Area me;
    public static List<Area> upAreaes;
    public static List<Area> downAreaes;
    public static RouteData routeData;

    static {
        //本域
        me = new Area();
        me.setName("荆州区");
        me.setSign("jzq.jz.hb.cn");
        me.setUrl("localhost:3003");

        //上级域
        upAreaes = new ArrayList<>();

        //下级域
        downAreaes = new ArrayList<>();
        Area cd = new Area();
        cd.setName("川店");
        cd.setSign("cd.jzq.jz.hb.cn");
        cd.setUrl("localhost:1003");
        Area ms = new Area();
        ms.setName("马山");
        ms.setSign("ms.jzq.jz.hb.cn");
        ms.setUrl("localhost:2003");
        downAreaes.add(cd);
        downAreaes.add(ms);

        //本域数据
        routeData = new RouteData();
        routeData.setType("branch");
        List<RouteData.BranchRoute> branchRoutes = routeData.getBranchRoutes();
        RouteData.BranchRoute cdRoute = new RouteData.BranchRoute();
        cdRoute.setSign("cd.jzq.jz.hb.cn");
        cdRoute.setName("川店");
        cdRoute.setCount(10);
        branchRoutes.add(cdRoute);
        RouteData.BranchRoute msRoute = new RouteData.BranchRoute();
        msRoute.setSign("ms.jzq.jz.hb.cn");
        msRoute.setName("马山");
        msRoute.setCount(5);
        branchRoutes.add(msRoute);
    }

    public static class Area{
        private String name;
        private String sign;
        private String url;

        public String getName() {
            return name;
        }

        public void setName(String name) {
            this.name = name;
        }

        public String getSign() {
            return sign;
        }

        public void setSign(String sign) {
            this.sign = sign;
        }

        public String getUrl() {
            return url;
        }

        public void setUrl(String url) {
            this.url = url;
        }
    }
}
